<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <video src="../douyin.mp4" controls="controls" width="400px"></video>
    <button>播放</button>
    <button>暂停</button>
    <button>快速播放</button>
    <button>快进</button>
    <button>快退</button>
    <button>重载</button>
    <button>大</button>
    <button>中</button>
    <button>小</button>
    <button>全屏</button>
    <script>
        var video = document.getElementsByTagName("video")[0];
        var btn = document.getElementsByTagName("button");
        btn[0].onclick = function() {
            video.play();
        }
        btn[1].onclick = function() {
                video.pause();
            }
            // 快速播放
        btn[2].onclick = function() {
                video.playbackRate = 2;
            }
            // 快进
        btn[3].onclick = function() {
                video.currentTime += 3;
            }
            // 快退
        btn[4].onclick = function() {
                video.currentTime -= 3;
            }
            // 重载
        btn[5].onclick = function() {
                video.load();
            }
            // 大
        btn[6].onclick = function() {
                video.width = "2000"
            }
            // 中
        btn[7].onclick = function() {
                video.width = "800"
            }
            // 小
        btn[8].onclick = function() {
            video.width = "400"
        }
        btn[9].onclick = function() {
            video.webkitRequestFullScreen();
        }
    </script>
</body>

</html>